home *** CD-ROM | disk | FTP | other *** search
/ Aminet 30 / Aminet 30 (1999)(Schatztruhe)[!][Apr 1999].iso / Aminet / mus / edit / BeatBoxUPD.lha / UpdateBeatBox2 / Update.BeatBox2 < prev    next >
Text File  |  1999-02-07  |  5KB  |  245 lines

  1. ;$VER:2.55 update
  2. ;installer script by Curt Esser
  3. ;last modified JAN 14 1999
  4. ;nah, it's not copyrighted  ©
  5. ;what could you do with it except install our program?
  6.  
  7. (complete 0)
  8.  
  9. ;(set @default-dest "WORK:")
  10.  
  11. ; Texts
  12.  
  13. (set #Intro-Txt
  14.   (cat "\nWelcome to "
  15.   "the BeatBox2 v2.55\n"
  16.   "Update Script\n\n"
  17.   "BeatBox2 is designed and programmed by:\n\n"
  18.   "James L. Boyd\n"
  19.   "and\n"
  20.   "Curt Esser\n\n"
  21.   "NOTE: You MUST have already installed BeatBox2 to use this update!"
  22. ))
  23.  
  24. (set #Locale-Txt
  25.   (cat "Check the Locale file(s) you want to install "
  26.        "in your SYS:Locale/ directory\n\n"
  27.        "NOTE:  It is NOT necessary to do this.\n"
  28.        "Please read the Help section first"
  29.        ))
  30.  
  31. (set #Locale-Help
  32.   (cat "This section will install the selected "
  33.        "Locale catalogs into your SYS:Locale/ directory.\n\n"
  34.        "NOTE:  If you have already installed the BeatBox2 "
  35.        "catalogs in SYS:Locale/ you should install these "
  36.        "new catalogs there too!  Otherwise you will "
  37.        "have problems with the Locale texts\n\n"   
  38.        "It is NOT necessary to do this if you do not "
  39.        "already have earlier BeatBox2 catalogs in "
  40.        "SYS:Locale/ \n\n"
  41.        "BeatBox2 will access the Locale files "
  42.        "from it's own directory, so there is really no need "
  43.        "to clutter up your Locale directory unless you "
  44.        "need to have them there for editing.\n\n"
  45.        ))
  46.  
  47. (set #Warning-Txt
  48.   (cat "Warning !\n\n\n"
  49.   "ReqTools.library not found in SYS:Libs/\n\n\n"
  50.   "You MUST install ReqTools.library before running BeatBox2!"
  51. ))
  52.  
  53. (set #CopyCat-Help
  54.   (cat "You only need these if you are using "
  55.        "a language other than English as your "
  56.        "Preferred Locale, "
  57.        "or if you use more than one Preferred Locale\n\n"
  58.        "NOTE: these are NEW Locale files, and if you "
  59.        "have installed the Locale files before, You "
  60.        "should install these too, or you will have "
  61.        "problems!"
  62. ))
  63.  
  64. (set #Path-Txt
  65.   (cat "Where is your current BeatBox2 directory?\n ")
  66. )
  67.  
  68.  
  69. (set #Path-Help
  70.   (cat "Please show me where your "
  71.        "BeatBox2 directory is located\n"
  72.        "Just select the directory where "
  73.        "You see the BeatBox2 drawer\n\n"
  74.        "Do NOT select the BeatBox2 "
  75.        "drawer itself!\n\n"
  76.        @askdir-help)
  77. )
  78.  
  79.  
  80.  
  81. ; Main ----------------------------
  82.  
  83. (message #Intro-Txt)
  84.  
  85. (IF (NOT (EXISTS "LIBS:reqtools.library"))
  86.     (message #Warning-Txt (all))
  87. )
  88.  
  89. (complete 10)
  90.  
  91. (set target         ; Where to install ? 
  92.   (askdir 
  93.     (prompt #Path-Txt) 
  94.     (help #Path-Help) 
  95.     (default @default-dest) 
  96.     (newpath)
  97.   )
  98. )
  99.  
  100. (set @default-dest target)
  101.  
  102.  
  103. (complete 25)
  104.  
  105. (if (= @user-level 2)
  106.  
  107.   (set #CatType       ;copy catalogs to Locale: ?
  108.   
  109.     (set Clog
  110.       (askoptions
  111.         (prompt #Locale-Txt) 
  112.         (help #Locale-Help)
  113.         (choices
  114.            "English"               ;Bit $01
  115.            "Français")             ;Bit $02 
  116.         (default 0)
  117.       )
  118.     )
  119.   )
  120. )
  121.  
  122.  
  123.  
  124. (complete 30)
  125.  
  126. ;we need to remove any old catalog files!
  127.  
  128. (IF (EXISTS (tackon target "BeatBox2/catalogs/english/Beatbox2.catalog"))
  129.     (DELETE
  130.      (tackon target "BeatBox2/catalogs/english/BeatBox2.catalog")
  131.     )
  132. )
  133.  
  134. (IF (EXISTS (tackon target "BeatBox2/catalogs/Français/BeatBox2.catalog"))
  135.     (DELETE
  136.     (tackon target "BeatBox2/catalogs/Français/BeatBox2.catalog")
  137.    )
  138. )    
  139.  
  140. (IF (EXISTS ( "SYS:Locale/catalogs/Français/BeatBox2.catalog"))
  141.     (DELETE
  142.      ("SYS:Locale/catalogs/Français/BeatBox2.catalog")
  143.     )
  144. )
  145.  
  146. (IF (EXISTS ( "SYS:Locale/catalogs/english/BeatBox2.catalog"))
  147.     (DELETE
  148.      ("SYS:Locale/catalogs/english/BeatBox2.catalog")
  149.     )
  150. )
  151.  
  152. (COMPLETE 40)
  153.  
  154.  
  155. ;---- Copy REQUIRED files ---
  156.  
  157. ; - NO choice - these are all required
  158.  
  159. (copyfiles
  160.   (prompt  "Copying BeatBox2")
  161.   (source "BeatBox2")
  162.   (dest (tackon target "BeatBox2"))
  163. )
  164.  
  165. (copyfiles
  166.   (prompt  "Copying BeatBox2.Prefs")
  167.   (source "BeatBox2.Prefs")
  168.   (dest (tackon target "BeatBox2"))
  169. )
  170.  
  171.  
  172. (complete 50)
  173.  
  174. (copyfiles
  175.   (prompt  "Copying Docs")
  176.   (source "Docs/")
  177.   (all)
  178.   (dest (tackon target "BeatBox2/Docs"))
  179. )
  180.  
  181. (IF (NOT 
  182.   (EXISTS (tackon target "BeatBox2/BeatBox2.key")
  183.   ))
  184.     (copyfiles 
  185.       (source "BeatBox2.key")
  186.       (dest (tackon target "BeatBox2/"))
  187.     )
  188. )
  189.  
  190.  
  191.  
  192. ; -- Copy OPTIONAL Files --
  193.  
  194. (if (= Clog $00)   ;skip this if they sent 'em to LOCALE:
  195.   (copyfiles
  196.     (prompt  "Copying Locale Catalogs")
  197.     (source "Catalogs/")
  198.     (all)
  199.     (dest (tackon target "BeatBox2/Catalogs"))
  200.     (help #CopyCat-Help)
  201.     (confirm)
  202.   )
  203. )
  204.  
  205. (complete 60)
  206.  
  207.  
  208. ; -- copy catalogs to Locale: if desired  
  209.  
  210. (if (bitand Clog $01)
  211.     (copyfiles
  212.       (prompt "Copying English Locale")
  213.       (help @copyfiles-help)
  214.       (source "catalogs/English")
  215.       (dest "Locale:catalogs/English/")
  216.       (confirm)
  217.       (all)
  218.     )
  219. )
  220.  
  221. (complete 80)  
  222.  
  223. (if (bitand Clog $02)
  224.     (copyfiles
  225.       (prompt "Copying Français Locale")
  226.       (help @copyfiles-help)
  227.       (source "catalogs/Français")
  228.       (dest "Locale:catalogs/Français")
  229.       (confirm)
  230.       (all)
  231.     )
  232. )  
  233.  
  234.  
  235.  
  236. (complete 100)
  237.  
  238. (exit "\n\nJames and Curt hope you enjoy BeatBox2\n\n" 
  239.       "You will find BeatBox2 v2.55 in your\n\n"
  240.       (target)" directory\n\n"
  241.       "\n\nPlease read the docs!"
  242.       (QUIET)
  243.  
  244. )
  245.